#ifndef __DEBUG_H
#define __DEBUG_H

#include <avr/io.h>
#include <stdio.h>
#include <stdint.h>
#include <avr/pgmspace.h>

//#define printf_p(fmt, ...) printf_P( PSTR( fmt ), ##__VA_ARGS__ )

/****************************************************************************
* Purpose:	Initializes debug serial port
* Input:	No Input
* Output:   No Output
****************************************************************************/
void debugInit(void);

/****************************************************************************
* Purpose:	putchar funtion used to allow stdio redirection. Writes a single
*			char to debug serial port
* Input:	char to be written and the file stream to write the file
* Output:   Always returns 0, return value is to comply with functptr type
****************************************************************************/
int	usart_putchar(char c, FILE *stream);
/*
#ifdef PROGMEM
#undef PROGMEM
#define PROGMEM __attribute__((section(".progmem.data")))
#endif*/

#endif /* __DEBUG_H */